package com.jiyun.client;

import com.jiyun.entity.Room;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;

import java.util.List;

@FeignClient("sushebase")
@RequestMapping("/sushebase/room")
public interface RoomClient {

    /**
     * 根据id查询实体接口
     */
    @RequestMapping("/findById")
    public Room findById(@RequestParam("id") Integer id);


    @RequestMapping("/update")
    public void updateRoom(@RequestBody Room room);

    @RequestMapping("findNoStuRoomNum")
    public Integer findNoStuRoomNum();

    @RequestMapping("/findAll")
    public List<Room> findAll();


}
